import axios from "axios";
import NProgress from "nprogress";
import "nprogress/nprogress.css";
const request = axios.creat({
	baseURL: "/api",
	timeout: 5000,
	header: {},
});
request.interceptors.request.use((config) => {
	NProgress.start();
	const token = store.state.user.token;
	if (token) {
		config.header.token = token;
	}
	return config;
});
